package com.achao.achaomq.controller;

import com.achao.achaomq.annotation.ApiMonitorAnnotation;
import com.achao.achaomq.service.NormalService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/achao/")
public class NormalController {

    @Autowired
    private NormalService normalService;

    @PostMapping("normal/test")
    @ApiMonitorAnnotation(apiModel = "achao",apiCode = "normal/test",apiName = "嵌套结果")
    public String testController(){
        System.out.println("我丢了");
        return normalService.normalTest();
    }

    @PostMapping("normal/test1")
    @ApiMonitorAnnotation(apiModel = "achao",apiCode = "normal/test1",apiName = "嵌套结果1")
    public String testController1(){
        return normalService.normalTest1();
    }

    @PostMapping("normal/nginxTest")
    public String testNginx(){
        System.out.println("Nginx测试进入");
        return "Nginx测试进入";
    }

}
